import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)
const store = new Vuex.Store({
	state: {
		// 宫格
		visibln: false,
		showtime: false,
		showjiesh: false,
		icon:false,
		zhuti: "",
		xiangxi: "",
		// 选项卡
		current: 0,
		flag: true,
		titleList: ['今天', '明天', '后天'],

		// 活动详情
		baoming:'报名'
	},
	mutations: {
		usegrid(state,bln) {
			state.flag = bln
		},
		showPic(state,bln) {
			state.visibln = bln
		},
		show(state,bln) {
			state.showtime = bln
		},
		queding(state,bln) {
			state.visibln = bln
		},
		Icon(state,bln) {
			state.icon = bln
		},
	},
	actions: {
		asyncUsegrid(context, asyncNewAge) {
				context.commit('usegrid',asyncNewAge)
		},
		asyncShowPic(context, asyncNewAge) {
				context.commit('showPic',asyncNewAge)
		},
		asyncShow(context, asyncNewAge) {
				context.commit('show',asyncNewAge)
		},
		asyncqueding(context, asyncNewAge) {
				context.commit('queding',asyncNewAge)
		},
		asyncIcon(context, asyncNewAge) {
				context.commit('Icon',asyncNewAge)
		},
	}
})
export default store
